package com.zxh.blog.domain;

public class Permission {
	Integer id;
	String name;
	String type;
	String url;
	String permission;
	Integer parent_id;
	Integer sort;
	Integer external;
	Integer available;
	String icon;
	String create_time;
	String update_time;

	@Override
	public String toString() {
		return "Permission{" +
				"id=" + id +
				", name='" + name + '\'' +
				", type='" + type + '\'' +
				", url='" + url + '\'' +
				", permission='" + permission + '\'' +
				", parent_id=" + parent_id +
				", sort=" + sort +
				", external=" + external +
				", available=" + available +
				", icon='" + icon + '\'' +
				", create_time='" + create_time + '\'' +
				", update_time='" + update_time + '\'' +
				'}';
	}

	@Override
	public boolean equals(Object o) {
		if (this == o) return true;
		if (o == null || getClass() != o.getClass()) return false;

		Permission that = (Permission) o;

		if (id != null ? !id.equals(that.id) : that.id != null) return false;
		if (name != null ? !name.equals(that.name) : that.name != null) return false;
		if (type != null ? !type.equals(that.type) : that.type != null) return false;
		if (url != null ? !url.equals(that.url) : that.url != null) return false;
		if (permission != null ? !permission.equals(that.permission) : that.permission != null) return false;
		if (parent_id != null ? !parent_id.equals(that.parent_id) : that.parent_id != null) return false;
		if (sort != null ? !sort.equals(that.sort) : that.sort != null) return false;
		if (external != null ? !external.equals(that.external) : that.external != null) return false;
		if (available != null ? !available.equals(that.available) : that.available != null) return false;
		if (icon != null ? !icon.equals(that.icon) : that.icon != null) return false;
		if (create_time != null ? !create_time.equals(that.create_time) : that.create_time != null) return false;
		return update_time != null ? update_time.equals(that.update_time) : that.update_time == null;

	}

	@Override
	public int hashCode() {
		int result = id != null ? id.hashCode() : 0;
		result = 31 * result + (name != null ? name.hashCode() : 0);
		result = 31 * result + (type != null ? type.hashCode() : 0);
		result = 31 * result + (url != null ? url.hashCode() : 0);
		result = 31 * result + (permission != null ? permission.hashCode() : 0);
		result = 31 * result + (parent_id != null ? parent_id.hashCode() : 0);
		result = 31 * result + (sort != null ? sort.hashCode() : 0);
		result = 31 * result + (external != null ? external.hashCode() : 0);
		result = 31 * result + (available != null ? available.hashCode() : 0);
		result = 31 * result + (icon != null ? icon.hashCode() : 0);
		result = 31 * result + (create_time != null ? create_time.hashCode() : 0);
		result = 31 * result + (update_time != null ? update_time.hashCode() : 0);
		return result;
	}

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}

	public String getUrl() {
		return url;
	}

	public void setUrl(String url) {
		this.url = url;
	}

	public String getPermission() {
		return permission;
	}

	public void setPermission(String permission) {
		this.permission = permission;
	}

	public Integer getParent_id() {
		return parent_id;
	}

	public void setParent_id(Integer parent_id) {
		this.parent_id = parent_id;
	}

	public Integer getSort() {
		return sort;
	}

	public void setSort(Integer sort) {
		this.sort = sort;
	}

	public Integer getExternal() {
		return external;
	}

	public void setExternal(Integer external) {
		this.external = external;
	}

	public Integer getAvailable() {
		return available;
	}

	public void setAvailable(Integer available) {
		this.available = available;
	}

	public String getIcon() {
		return icon;
	}

	public void setIcon(String icon) {
		this.icon = icon;
	}

	public String getCreate_time() {
		return create_time;
	}

	public void setCreate_time(String create_time) {
		this.create_time = create_time;
	}

	public String getUpdate_time() {
		return update_time;
	}

	public void setUpdate_time(String update_time) {
		this.update_time = update_time;
	}

}
